package com.usian.feign;


import com.usian.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "ribbon-provider")
public interface UserFeign {

    @RequestMapping("/user/findUserById/{userId}")
    public User findUserById(@PathVariable Integer userId);

    @RequestMapping("/user/findById")
    public User findById(@RequestParam Integer id);

    @RequestMapping("/user/insertUser")
    public String insertUser(@RequestBody User user);

}
